package cn.geminis.workflow.service.service.engine.expression;

import cn.geminis.workflow.service.utils.SpringUtils;
import org.flowable.common.engine.api.delegate.Expression;
import org.flowable.engine.impl.el.ProcessExpressionManager;
import org.springframework.stereotype.Service;

/**
 * @author puddi
 */
@Service
public class GeminiExpressionManager extends ProcessExpressionManager {

    @Override
    public Expression createExpression(String text) {
        var valueContext = SpringUtils.getBean(ExpressionValueContext.class);
        return new GeminiExpression(super.createExpression(text), valueContext);
    }
}
